//轮播图
var mainimgList = [
	{
		img: "./images/lunbotu/bg4.jpg",
		url: "https://mp.weixin.qq.com/s/pVexXVhdUCXw6e9ifU00FA",
	},
	{
		img: "./images/lunbotu/bg3.jpg",
		url: "https://mp.weixin.qq.com/s/ylGU4H_1Zz7XNmJU8kX-Bg",
	},
	{
		img: "./images/lunbotu/bg2.jpg",
		url: "https://mp.weixin.qq.com/s/VWOmHaeqJLQmD_Rez6HfkQ",
	},
	{
		img: "./images/lunbotu/bg1.jpg",
		url: "http://mp.weixin.qq.com/mp/homepage?__biz=MzUwOTMwMjExNQ==&hid=5&sn=b5844538f6f0a49eb2423a900f19d888&scene=18#wechat_redirect", //javascript:;
	}
]

var mainimg = document.getElementsByClassName('main_img')[0]
var imgfont = document.getElementsByClassName('img_font')[0]
for (var i = 0; i < mainimgList.length; i++) {
	mainimg.innerHTML += "<li><a href=" + mainimgList[i].url + "><img style='height:12rem;width:100%;' src=" +
		mainimgList[i].img + " alt=''></a></li>"
	imgfont.innerHTML += '<span>' + (Number(i) + 1) + '/' + mainimgList.length + '</span>'
}


// 轮播推荐消息
var newsList = [{
		name: "'万能导入法'讲解说明",
		url: "https://mp.weixin.qq.com/s/RWIexQuq5BOSuq_6mSqmBg"
	}, {
		name: "【无名杀界面美化教程】精品文章，建议收藏",
		url: "https://mp.weixin.qq.com/s/GvVMUqhPS9x7ByZQF4RsMg"
	},
	{
		name: "无名杀私服联机地址分享",
		url: "https://mp.weixin.qq.com/s/uHvlWIae84Rp4NuQg28dUg"
	}
]
var newsLi = document.getElementsByClassName('news_li')[0]
for (var i = 0; i < newsList.length; i++) {
	newsLi.innerHTML += "<li><a href=" + newsList[i].url + ">" + newsList[i].name + "</a></li>"
}



// 推荐QQ群
var qqList = [
	{
		name: "无名杀武将界...",
		url: "https://jq.qq.com/?_wv=1027&k=Ix454vYe",
		img: "images/qun/1.jpg",
		renshu: "631",
		qunhao: "953072933"
	},
	{
		name: "无名杀特效测...",
		url: "https://jq.qq.com/?_wv=1027&k=du4ua9hE",
		img: "images/qun/2.jpg",
		renshu: "500",
		qunhao: "288155120"
	},
	{
		name: "无名杀将灵扩...",
		url: "https://jq.qq.com/?_wv=1027&k=w2jgmLJS",
		img: "images/qun/3.jpg",
		renshu: "588",
		qunhao: "634971615"
	},
	{
		name: "無名殺官方群Ⅰ",
		url: "https://jq.qq.com/?_wv=1027&k=zDIx5seq",
		img: "images/qun/noname.jpg",
		renshu: "2000",
		qunhao: "335438250"
	},
	{
		name: "无名杀官方群Ⅱ",
		url: "https://jq.qq.com/?_wv=1027&k=Pdk1cRAv",
		img: "images/qun/noname2.jpg",
		renshu: "1505",
		qunhao: "348943983"
	},
	{
		name: "无名杀官方群Ⅲ",
		url: "https://jq.qq.com/?_wv=1027&k=FUjuVEj5",
		img: "images/qun/noname3.jpg",
		renshu: "1632",
		qunhao: "459406548"
	},
	{
		name: "无名杀官方群Ⅳ",
		url: "https://jq.qq.com/?_wv=1027&k=4ZFYSz1D",
		img: "images/qun/noname4.jpg",
		renshu: "1530",
		qunhao: "618725633"
	},
	{
		name: "无名杀官方群Ⅴ",
		url: "https://jq.qq.com/?_wv=1027&k=6AORijG8",
		img: "images/qun/noname5.jpg",
		renshu: "1531",
		qunhao: "518258435"
	},
	{
		name: "无名杀官方群Ⅵ",
		url: "https://jq.qq.com/?_wv=1027&k=lk5NJkW0",
		img: "images/qun/noname6.jpg",
		renshu: "1999",
		qunhao: "536979725"
	},
	{
		name: "无名杀官方群Ⅶ",
		url: "https://jq.qq.com/?_wv=1027&k=qGOQlj6T",
		img: "images/qun/noname7.jpg",
		renshu: "1725",
		qunhao: "1080968725"
	},
	{
		name: "无名杀官方群Ⅷ",
		url: "https://jq.qq.com/?_wv=1027&k=vBGutFiU",
		img: "images/qun/noname8.jpg",
		renshu: "1893",
		qunhao: "1038572358"
	},
	{
		name: "无名杀官方群Ⅸ",
		url: "https://jq.qq.com/?_wv=1027&k=d1TYSKpj",
		img: "images/qun/noname9.jpg",
		renshu: "1971",
		qunhao: "292753743"
	},
	{
		name: "无名杀官方群Ⅹ",
		url: "https://jq.qq.com/?_wv=1027&k=VH4hX5VX",
		img: "images/qun/noname.jpg",
		renshu: "2423",
		qunhao: "784051469"
	},
	{
		name: "十周年UI（手...",
		url: "https://jq.qq.com/?_wv=1027&k=QGTOZ0id",
		img: "images/qun/ui.jpg",
		renshu: "899",
		qunhao: "421537580"
	},
	{
		name: "无名杀玄武...",
		url: "https://jq.qq.com/?_wv=1027&k=b0cBTIdn",
		img: "images/qun/xw.jpg",
		renshu: "1987",
		qunhao: "522136249"
	},
	{
		name: "无名杀金庸...",
		url: "https://jq.qq.com/?_wv=1027&k=3oIvkguA",
		img: "images/qun/jy.jpg",
		renshu: "467",
		qunhao: "697310426"
	},
	{
		name: "无名杀–秦时...",
		url: "https://jq.qq.com/?_wv=1027&k=Es1Spigs",
		img: "images/qun/qinshi.jpg",
		renshu: "94",
		qunhao: "616483541"
	},
]
var qq = document.getElementsByClassName("aui-slide-item-list")[0]
for (var i = 0; i < qqList.length; i++) {
	qq.innerHTML += '<li class="aui-slide-item-item"><a href=' + qqList[i].url + ' class="aui-link"><img src=' +
		qqList[i].img + ' alt=""></a><div class="aui-good-content"><h3>' + qqList[i].name + '</h3><p>' + qqList[i]
		.renshu + '人</p><span>群号:' + qqList[i].qunhao + '</span></div></li>'
}



// 热门扩展
var auiPatternList = [{
		name: "玄武江湖",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=1712682190653718529#wechat_redirect"
	},
	{
		name: "武将界面",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171829568414842885#wechat_redirect"
	},
	{
		name: "十周年ui",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171834109554229250#wechat_redirect"
	},
	{
		name: "手杀ui",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171835779608641538#wechat_redirect"
	},
	{
		name: "时空枢纽",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171838814690902017#wechat_redirect"
	},
	{
		name: "RE：英雄杀",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171841663814500356#wechat_redirect"
	},
	{
		name: "千幻聆音",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171840466793693185#wechat_redirect"
	},
	{
		name: "在线更新",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171845782168043531#wechat_redirect"
	},
	{
		name: "特效测试",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171843384468996104#wechat_redirect"
	},
	{
		name: "极略自用",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171847276984434690#wechat_redirect"
	},
	{
		name: "将灵",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2171848492963495938#wechat_redirect"
	},
	{
		name: "秦时明月",
		url: "https://mp.weixin.qq.com/mp/appmsgalbum?__biz=MzUwOTMwMjExNQ==&action=getalbum&album_id=2065836389295882241#wechat_redirect"
	}
]
var auiPattern = document.getElementsByClassName('aui-pattern')[0]
for (var j = 0; j < auiPatternList.length; j++) {
	auiPattern.innerHTML += "<a href=" + auiPatternList[j].url + ">" + auiPatternList[j].name + "</a>"
}

//资讯广场

var zixun = document.getElementsByClassName('zixun')[0]
zixun.onclick = function() {

	var broser = window.navigator.userAgent.toLowerCase();
	//通过正则表达式匹配broser 中是否含有MicroMessenger字符串
	if (broser.match(/MicroMessenger/i) == 'micromessenger') {
		alert('请选择"在浏览器打开",再进入"资讯广场"')
	} else {
		window.location.href = 'https://static-64bbfebf-7fd8-4fcb-9faf-c05bd62be4ed.bspapp.com/#/';
	}


}
